using System;
using System.ComponentModel.DataAnnotations;
using WalkingTec.Mvvm.Core;

namespace HengTong.Model.Db.SupplyChain.Warehouse;

/// <summary>
/// 库区实体类
/// 用于管理仓库内的分区信息，支持树形结构
/// </summary>
[Display(Name = "库区", Description = "仓库库区管理", GroupName = "供应链")]
public class SysWarehouseArea : TreePoco<SysWarehouseArea>
{
    /// <summary>
    /// 库区名称
    /// </summary>
    [Display(Name = "库区名称", Description = "库区名称", GroupName = "基本信息")]
    [StringLength(128)]
    public string Name { get; set; }
    
    /// <summary>
    /// 库区编码
    /// </summary>
    [Display(Name = "库区编码", Description = "库区编码", GroupName = "基本信息")]
    [StringLength(128)]
    public string Code { get; set; }
    
    /// <summary>
    /// ERP系统中的编号
    /// </summary>
    [Display(Name = "ERP编号", Description = "ERP系统中的编号", GroupName = "基本信息")]
    [StringLength(128)]
    public string ErpId { get; set; }
    
    /// <summary>
    /// 关联的仓库
    /// </summary>
    [Display(Name = "所属仓库", Description = "关联的仓库", GroupName = "关联信息")]
    public SysWarehouse Warehouse { get; set; }
    
    /// <summary>
    /// 关联的仓库ID
    /// </summary>
    [Display(Name = "仓库ID", Description = "关联的仓库ID", GroupName = "关联信息")]
    public Guid? WarehouseId { get; set; }
    
    /// <summary>
    /// 库区描述信息
    /// </summary>
    [Display(Name = "描述", Description = "库区描述信息", GroupName = "基本信息")]
    [StringLength(512)]
    public string Description { get; set; }
    
    /// <summary>
    /// 库区状态
    /// </summary>
    [Display(Name = "状态", Description = "库区状态", GroupName = "基本信息")]
    public CommonState CommonState { get; set; }
}